package com.citcc.business.service;

import java.util.List;

import com.citcc.business.bean.TCdzTimeType;
import com.citcc.common.support.Convert;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.citcc.business.mapper.TCdzTimeTypeMapper;

/**
 * 充电时长 服务层实现
 *
 * @author itqinbo
 * @date 2019-04-09
 */
@Service
public class TCdzTimeTypeService {
    @Autowired
    private TCdzTimeTypeMapper tCdzTimeTypeMapper;

    /**
     * 查询充电时长信息
     *
     * @param id 充电时长ID
     * @return 充电时长信息
     */
    public TCdzTimeType selectTCdzTimeTypeById(String id) {
        return tCdzTimeTypeMapper.selectTCdzTimeTypeById(id);
    }

    /**
     * 查询充电时长列表
     *
     * @param tCdzTimeType 充电时长信息
     * @return 充电时长集合
     */
    public List<TCdzTimeType> selectTCdzTimeTypeList(TCdzTimeType tCdzTimeType) {
        return tCdzTimeTypeMapper.selectTCdzTimeTypeList(tCdzTimeType);
    }

    /**
     * 新增充电时长
     *
     * @param tCdzTimeType 充电时长信息
     * @return 结果
     */
    public int insertTCdzTimeType(TCdzTimeType tCdzTimeType) {
        return tCdzTimeTypeMapper.insertTCdzTimeType(tCdzTimeType);
    }

    /**
     * 修改充电时长
     *
     * @param tCdzTimeType 充电时长信息
     * @return 结果
     */
    public int updateTCdzTimeType(TCdzTimeType tCdzTimeType) {
        return tCdzTimeTypeMapper.updateTCdzTimeType(tCdzTimeType);
    }

    /**
     * 删除充电时长对象
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    public int deleteTCdzTimeTypeByIds(String ids) {
        return tCdzTimeTypeMapper.deleteTCdzTimeTypeByIds(Convert.toStrArray(ids));
    }

}
